<template>
    <div id="classify">
      <v-touch v-on:swipeleft="swiperleft"  v-on:swiperight="swiperright" class="wrapper" style="touch-action: pan-y!important;">
       <div class="tit">
        全部 · 人气推荐
        <img src="../../../assets/imgs/detail/arr1.png" alt="">
       </div>
       <div class="comic-bar" v-if="$store.state.states">
        <div v-for="(item,index) in $store.state.comic" :key="index" @click="detail(item)">
          <img :src="item.imgUrl" alt="">
          <h3>{{item.name}}</h3>
          <p>更新至{{item.beUpdateTo}}话</p>
        </div>
       </div>
      </v-touch>
    </div>
</template>

<script>
    export default {
        name: "Classify",
      methods:{
        swiperleft: function () {
          this.$router.push({'path': '/find/free'});
        },
        swiperright: function () {
          this.$router.push({'path': '/homePage'});
        },
        detail(obj){
          // console.log(obj);
          this.$router.push({name:'Detail',query:obj})
        }
      }
    }
</script>

<style lang="less">
@import "../../../assets/css/find/classify";
</style>
